﻿@model DaBF.Models.Category

@{
    ViewData["Title"] = "View";
}

<h1>View</h1>

<h4>Category</h4>
<hr />
<div class="row">
    <div class="col-md-4">
        <form asp-action="View">
            <div asp-validation-summary="ModelOnly" class="text-danger"></div>
            <div class="form-group">
                <label asp-for="CategoryName" class="control-label"></label>
                <input asp-for="CategoryName" class="form-control" />
                <span asp-validation-for="CategoryName" class="text-danger"></span>
            </div>
            <div class="form-group">
                <label  class="control-label"></label>
                <select asp-for="ParentCategoryId"  class ="form-control"  asp-items="ViewBag.Categorys"></select>

            </div>
            <div class="form-group">
                <input type="submit" value="Create" class="btn btn-primary" />
            </div>
        </form>
    </div>
</div>

<div>
    <a asp-action="CategoryList">返还列表</a>
</div>

